﻿<%@ Page Language="C#" MasterPageFile="~/MP/Classic.master" AutoEventWireup="true"
    CodeBehind="SearchResumes.aspx.cs" Inherits="Careers_SearchResumes" RoleHint="Recruiter" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="PageContainer" runat="Server">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <h1>
                Search Resumes</h1>
            <br />
            <fieldset class="collpasibleFieldset">
                <asp:Panel ID="FiltersHeader" runat="server" CssClass="collapsiblePanelHeader">
                    <h2 style="margin: 0px">
                        <asp:ImageButton ID="FiltersHeaderImage" runat="server" ImageUrl="~/MM/imx/bottom.png"
                            AlternateText="(Show...)" Style="float: right; position: relative; top: -2px;
                            background-color: Transparent !important" />
                        Search Filters</h2>
                </asp:Panel>
                <asp:Panel class="jobSection clear" ID="FiltersPanel" runat="server">
                    <br />
                    <table>
                        <tr>
                            <td>
                                <asp:Label ID="AddressLabel" runat="server" Text="Address = "></asp:Label>
                            </td>
                            <td colspan="3">
                                <asp:TextBox ID="AddressTextBox" runat="server"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <asp:Label ID="FromLabel" runat="server" Text="Date from"></asp:Label>
                            </td>
                            <td>
                                <asp:TextBox ID="FromTextBox" runat="server"></asp:TextBox>
                            </td>
                            <td>
                                <asp:Label ID="ToLabel" runat="server" Text="To"></asp:Label>
                            </td>
                            <td>
                                <asp:TextBox ID="ToTextBox" runat="server"></asp:TextBox>
                            </td>
                        </tr>
                    </table>
                    <br />
                    <asp:Panel ID="CustomFieldsPanel" runat="server" Style="border-bottom: 1px dotted #555;
                        border-top: 1px dotted #555" Width="95%">
                        <table width="100%">
                            <tr>
                                <td colspan="4">
                                    <h3>
                                        Custom Filters</h3>
                                </td>
                            </tr>
                            <tr>
                                <td width="38%">
                                    Field: &nbsp;&nbsp;<asp:DropDownList ID="CustomFieldsDropDownList" runat="server"
                                        Width="120">
                                    </asp:DropDownList>
                                </td>
                                <td width="42%">
                                    Value = &nbsp;&nbsp;<asp:TextBox ID="CustomValueTextBox" runat="server" Width="100"></asp:TextBox>
                                </td>
                                <td width="10%">
                                    <asp:DropDownList ID="ConnectorsList" runat="server">
                                        <asp:ListItem>And</asp:ListItem>
                                        <asp:ListItem>Or</asp:ListItem>
                                    </asp:DropDownList>
                                </td>
                                <td align="right">
                                    <asp:Button ID="Add" runat="server" Text="Add" OnClick="AddButton_Click" />
                                </td>
                            </tr>
                            <tr>
                                <td colspan="4">
                                    <br />
                                    <asp:GridView ID="CustomFiltersGridView" runat="server" AutoGenerateColumns="False"
                                        Width="100%">
                                        <Columns>
                                            <asp:BoundField DataField="Name" HeaderText="Field Name" />
                                            <asp:BoundField DataField="Value" HeaderText="Field Value" />
                                            <asp:BoundField DataField="LogicalConnector" HeaderText="Logical Operation" />
                                        </Columns>
                                    </asp:GridView>
                                </td>
                            </tr>
                        </table>
                    </asp:Panel>
                    <br />
                    <table width="95%">
                        <tr>
                            <td>
                                <asp:CheckBox ID="CrossTenantCheckBox" runat="server" Text="Search in multiple tenant information." />
                            </td>
                            <td colspan="2" align="right">
                                <asp:Button ID="ClearButton" runat="server" Text="Clear" OnClick="ClearButton_Click" />&nbsp;&nbsp;&nbsp;
                                <asp:Button ID="SearchButton" runat="server" Text="Search" OnClick="SearchButton_Click" />
                            </td>
                        </tr>
                    </table>
                </asp:Panel>
                <cc1:CollapsiblePanelExtender ID="PersonalDataCollapsiblePanelExtender" runat="server"
                    TargetControlID="FiltersPanel" ExpandControlID="FiltersHeader" CollapseControlID="FiltersHeader"
                    Collapsed="False" ImageControlID="FiltersHeaderImage" ExpandedText="(Hide...)"
                    CollapsedText="(Show...)" ExpandedImage="~/MM/imx/top.png" CollapsedImage="~/MM/imx/bottom.png"
                    SuppressPostBack="true" />
            </fieldset>
            <br />
            <fieldset class="collpasibleFieldset">
                <asp:Panel ID="ResumesHeader" runat="server" CssClass="collapsiblePanelHeader">
                    <h2 style="margin: 0px">
                        <asp:ImageButton ID="ResumesHeaderImage" runat="server" ImageUrl="~/MM/imx/bottom.png"
                            AlternateText="(Show...)" Style="float: right; position: relative; top: -2px;
                            background-color: Transparent !important" />
                        Your Applications</h2>
                </asp:Panel>
                <asp:Panel class="jobSection clear" ID="ResumesPanel" runat="server">
                    <table>
                        <tr>
                            <td>
                                <asp:GridView ID="ResumeResultGridView" runat="server" AutoGenerateColumns="false"
                                    OnRowDataBound="ResumeResultGridView_RowDataBound" Width="45%">
                                    <Columns>
                                        <asp:HyperLinkField DataNavigateUrlFields="Id,PositionId" HeaderText="Resume details"
                                            Text="View details" />
                                        <asp:BoundField DataField="ApplicantName" HeaderText="Applicant Name" />
                                        <asp:BoundField DataField="ApplicantLastName" HeaderText="Last name" />
                                        <asp:BoundField DataField="Address" HeaderText="Address" />
                                        <asp:BoundField DataField="PhoneNumber" HeaderText="Phone number" />
                                        <asp:BoundField DataField="Date" HeaderText="Submission Date" />
                                    </Columns>
                                </asp:GridView>
                            </td>
                        </tr>
                    </table>
                </asp:Panel>
                <cc1:CollapsiblePanelExtender ID="CollapsiblePanelExtender1" runat="server" TargetControlID="ResumesPanel"
                    ExpandControlID="ResumesHeader" CollapseControlID="ResumesHeader" Collapsed="False"
                    ImageControlID="ResumesHeaderImage" ExpandedText="(Hide...)" CollapsedText="(Show...)"
                    ExpandedImage="~/MM/imx/top.png" CollapsedImage="~/MM/imx/bottom.png" SuppressPostBack="true" />
            </fieldset>
            <br />
            <asp:Panel ID="CrossTenantPanel" Visible="false" runat="server">
                <fieldset class="collpasibleFieldset">
                    <asp:Panel ID="ExternalResumesHeader" runat="server" CssClass="collapsiblePanelHeader">
                        <h2 style="margin: 0px">
                            <asp:ImageButton ID="ExternalResumesHeaderImage" runat="server" ImageUrl="~/MM/imx/bottom.png"
                                AlternateText="(Show...)" Style="float: right; position: relative; top: -2px;
                                background-color: Transparent !important" />
                            External Tenants Applications</h2>
                    </asp:Panel>
                    <asp:Panel class="jobSection clear" ID="ExternalResumesPanel" runat="server">
                        <table>
                            <tr>
                                <td>
                                    <asp:GridView ID="CrossTenantResumeResultGridView" runat="server" AutoGenerateColumns="False"
                                        Width="70%" onrowdatabound="CrossTenantResumeResultGridView_RowDataBound">
                                        <Columns>
                                            <asp:BoundField DataField="ApplicantName" HeaderText="Applicant Name" />
                                            <asp:BoundField DataField="ApplicantLastName" HeaderText="Last name" />
                                            <asp:BoundField DataField="Address" HeaderText="Address" />
                                            <asp:BoundField DataField="PhoneNumber" HeaderText="Phone number" />
                                            <asp:BoundField DataField="Date" HeaderText="Submission Date" />
                                            <asp:TemplateField>
                                                <ItemTemplate>
                                                    <asp:Panel ID="PopupDetails" runat="server">
                                                        <asp:GridView ID="ResumeDetailsGridView" runat="server" AutoGenerateColumns="false">
                                                            <Columns>
                                                                <asp:BoundField DataField="Name" HeaderText="Field" />
                                                                <asp:BoundField DataField="Value" />
                                                            </Columns>
                                                        </asp:GridView>
                                                    </asp:Panel>
                                                    <asp:Panel ID="ViewDetailsPanel" runat="server">
                                                        View custom fields...</asp:Panel>
                                                    <cc1:HoverMenuExtender ID="hme2" runat="Server" PopupControlID="PopupDetails" PopupPosition="Right"
                                                        TargetControlID="ViewDetailsPanel" PopDelay="25" />
                                                </ItemTemplate>
                                            </asp:TemplateField>
                                        </Columns>
                                    </asp:GridView>
                                </td>
                            </tr>
                        </table>
                    </asp:Panel>
                    <cc1:CollapsiblePanelExtender ID="CollapsiblePanelExtender2" runat="server" TargetControlID="ExternalResumesPanel"
                        ExpandControlID="ExternalResumesHeader" CollapseControlID="ExternalResumesHeader"
                        Collapsed="False" ImageControlID="ExternalResumesHeaderImage" ExpandedText="(Hide...)"
                        CollapsedText="(Show...)" ExpandedImage="~/MM/imx/top.png" CollapsedImage="~/MM/imx/bottom.png"
                        SuppressPostBack="true" />
                </fieldset></asp:Panel>
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>
